package com.code.day17;

import java.util.stream.Stream;

public class Demo06Stream {
    public static void main(String[] args) {
        Stream<String> stream = Stream.of("哪吒传奇", "小鲤鱼历险记", "虹猫蓝兔七侠传", "飞天小女警", "猫眼三姐妹","飞天小女警");
        stream.distinct().forEach(System.out::println);
        System.out.println("===================");
        Stream.of(new Person("刘大胆", 18), new Person("刘大胆", 18)).distinct().forEach(System.out::println);
    }
}
